{% extends 'base.html' %}
{% load custom_filters %}
{% block title %}换电站列表{% endblock %}
{% block content %}
<div class="row">
    <div class="col" align="center">
        <h2>{{business_unit}}</h2>
    </div>
</div>
<div class="row">
    {% if stations %}
    <div class="col">
        <table class="table table-striped">
            <thead>
                    <tr>
                        <th>换电站编号</th>
                        <th>换电站名称</th>
                        <th>换电站厂家</th>
                        <th>换电站型号</th>
                        <th>架载机数量</th>
                        <th>备电数量</th>
                        <th>复核数量</th>
                    </tr>
                </thead>
                <tbody>
                {% for station in stations %}
                    <tr>
                        <td>{{ station.station_id }}</td>
                        <td>{{ station.station_name }}</td>
                        <td>{{ station.station_maker }}</td>
                        <td>{{ station.station_type }}</td>
                        <td>{{ station.charger_count }}</td>
                        <td>{{ station.battery_count}}</td>
                        <td><a href="/ai_inspect/station_battery_count_validate/{{station.station_id}}/">{{ station.battery_count_validate }}</a></td>
                    </tr>
                {% endfor %}
                </tbody>
        </table>
    </div>
    {% else %}
    <div class="col">
        <div class="alert alert-danger" role="alert">未检索到换电站</div>
    </div>
    {% endif %}
</div>
{% endblock %}